package baseFx.database.mybatis.impl;

import baseFx.database.CursorReader;
import baseFx.database.MultipleReader;
import baseFx.database.SqlParam;
import baseFx.database.mybatis.MybatisDbQuery;
import baseFx.database.mybatis.MybatisQuery;
import baseFx.database.query.PageData;
import baseFx.database.query.PageSet;

import java.util.List;

public class MysqlQuery extends baseFx.database.query.impl.MysqlQuery implements MybatisDbQuery {
    private MybatisQuery query;

    public MysqlQuery(MybatisQuery query) {
        super(query);
        this.query = query;
    }

    @Override
    public <T> List<T> stmtQuery(Class<T> clazz, SqlParam param) {
        return query.stmtQuery(clazz, param);
    }

    @Override
    public MultipleReader stmtMultiple(SqlParam param) {
        return query.stmtMultiple(param);
    }

    @Override
    public <T> PageData<T> stmtPager(Class<T> clazz, PageSet pageSet, SqlParam param) {
        return query.stmtPager(clazz, pageSet, param);
    }

    @Override
    public <T> CursorReader<T> stmtCursor(Class<T> clazz, SqlParam param, int fetchSize, boolean independent) {
        return query.stmtCursor(clazz, param, fetchSize, independent);
    }
}
